package assignment12;

import java.util.*;

public class Movie { 
    private String title, type; 
    //演员表
    private Vector<String> actors;
    
    //get方法
	public String getTitle() { return title; }
    public String getType() { return type; }
    public Vector<String> getActors() { return actors; }
    
    //set方法
    public void setTitle(String aTitle) { title = aTitle; } 
    public void setType(String aType) { type = aType; } 
    
    //默认构造
    public Movie() {   
    	this("???", "???");  
    } 
    
    public Movie(String aTitle, String aType) { 
        title = aTitle;
        type = aType;
        actors = new Vector<String>();
    }
    
    public String toString() { 
        return("《" + title + "》"); 
    } 
    
    public void addActor(String anActor) { 
    	actors.add(anActor);  
    } 
}